<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <title> New Document </title>
  <meta charset="utf-8">
  <meta name="Generator" content="EditPlus">
  <meta name="Author" content="">
  <meta name="Keywords" content="">
  <meta name="Description" content="">
  <style>
  #one{
  width:200px;
  height:200px;
  background-color:red;
  border:1px solid black;
  }
  </style>
 </head>

 <body>
	<div id="one">浮动</div>
 </body>
   <script type="text/javascript">
	var a = document.getElementById('one');
	 var i =1.22;

   
	function dongtai(){
		a.style.marginTop=i+'px';
		a.style.width=i+'px';
		i++;
		setTimeout(dongtai,10);
	}
	dongtai();
  </script>
</html>
